package com.mdhw.order.dao;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.mdhw.order.entity.JiaOrder;
import com.mdhw.order.vo.JiaOrderVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface JiaOrderDao extends BaseMapper<JiaOrder> {
    int deleteByPrimaryKey(Integer id);

    int insert(JiaOrder record);

    int insertSelective(JiaOrder record);

    JiaOrder selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(JiaOrder record);

    int updateByPrimaryKey(JiaOrder record);


    IPage<JiaOrderVo> selectJiarOrderPageVo(IPage<JiaOrderVo> page, @Param(Constants.WRAPPER) Wrapper<JiaOrderVo> queryWrapper);
    IPage<JiaOrderVo> selectJiarOrderWithShangwuOrderPageVo(IPage<JiaOrderVo> page, @Param(Constants.WRAPPER) Wrapper<JiaOrderVo> queryWrapper);

    List<JiaOrderVo> selectSumOrderPriceByIds(@Param(Constants.WRAPPER) Wrapper<JiaOrderVo> jovQw);
}